package xyz.yang.toodles.statemachine;

/**
 * @author Xuehong Yang
 * @since 1.0
 */
public interface Process<S extends State, E extends Event> {

    default void process(E event, String comment) {
        addProcessStep(event, comment);
        transfer(event);
    }

    void transfer(E event);

    void addProcessStep(E event, String comment);
}
